/*
 * XML Type:  PaymentModResponse
 * Namespace: http://ofx.net/types/2003/04
 * Java type: net.ofx.types.x2003.x04.PaymentModResponse
 *
 * Automatically generated - do not modify.
 */
package net.ofx.types.x2003.x04.impl;
/**
 * An XML PaymentModResponse(@http://ofx.net/types/2003/04).
 *
 * This is a complex type.
 */
public class PaymentModResponseImpl extends net.ofx.types.x2003.x04.impl.AbstractPaymentResponseImpl implements net.ofx.types.x2003.x04.PaymentModResponse
{
    
    public PaymentModResponseImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName PMTINFO$0 = 
        new javax.xml.namespace.QName("", "PMTINFO");
    private static final javax.xml.namespace.QName PMTPRCSTS$2 = 
        new javax.xml.namespace.QName("", "PMTPRCSTS");
    
    
    /**
     * Gets the "PMTINFO" element
     */
    public net.ofx.types.x2003.x04.PaymentInfo getPMTINFO()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.PaymentInfo target = null;
            target = (net.ofx.types.x2003.x04.PaymentInfo)get_store().find_element_user(PMTINFO$0, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * Sets the "PMTINFO" element
     */
    public void setPMTINFO(net.ofx.types.x2003.x04.PaymentInfo pmtinfo)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.PaymentInfo target = null;
            target = (net.ofx.types.x2003.x04.PaymentInfo)get_store().find_element_user(PMTINFO$0, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.PaymentInfo)get_store().add_element_user(PMTINFO$0);
            }
            target.set(pmtinfo);
        }
    }
    
    /**
     * Appends and returns a new empty "PMTINFO" element
     */
    public net.ofx.types.x2003.x04.PaymentInfo addNewPMTINFO()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.PaymentInfo target = null;
            target = (net.ofx.types.x2003.x04.PaymentInfo)get_store().add_element_user(PMTINFO$0);
            return target;
        }
    }
    
    /**
     * Gets the "PMTPRCSTS" element
     */
    public net.ofx.types.x2003.x04.PaymentProcessingStatus getPMTPRCSTS()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.PaymentProcessingStatus target = null;
            target = (net.ofx.types.x2003.x04.PaymentProcessingStatus)get_store().find_element_user(PMTPRCSTS$2, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * True if has "PMTPRCSTS" element
     */
    public boolean isSetPMTPRCSTS()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(PMTPRCSTS$2) != 0;
        }
    }
    
    /**
     * Sets the "PMTPRCSTS" element
     */
    public void setPMTPRCSTS(net.ofx.types.x2003.x04.PaymentProcessingStatus pmtprcsts)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.PaymentProcessingStatus target = null;
            target = (net.ofx.types.x2003.x04.PaymentProcessingStatus)get_store().find_element_user(PMTPRCSTS$2, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.PaymentProcessingStatus)get_store().add_element_user(PMTPRCSTS$2);
            }
            target.set(pmtprcsts);
        }
    }
    
    /**
     * Appends and returns a new empty "PMTPRCSTS" element
     */
    public net.ofx.types.x2003.x04.PaymentProcessingStatus addNewPMTPRCSTS()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.PaymentProcessingStatus target = null;
            target = (net.ofx.types.x2003.x04.PaymentProcessingStatus)get_store().add_element_user(PMTPRCSTS$2);
            return target;
        }
    }
    
    /**
     * Unsets the "PMTPRCSTS" element
     */
    public void unsetPMTPRCSTS()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(PMTPRCSTS$2, 0);
        }
    }
}
